package com.cocolover2.andbase.contants;

/**
 * 正则表达式常量
 * Created by Administrator on 2015/8/25.
 */
public class RegexContants {

    private RegexContants() {
        throw new UnsupportedOperationException("cannot be instantiated");
    }

    public static final String regex_number_letter = "(\\d|\\w)+";// 数字或字母
    /**
     * 电话号码匹配(包括固话和手机号码)
     */
    public static final String regex_phone = "(0\\d{2,3}\\d{7,8})|(1[3458]\\d{9})";
    /**
     * 邮政编码匹配
     */
    public static final String regex_ems = "\\d{6}";
    /**
     * 邮箱匹配
     */
    public static final String regex_email = "^([a-z0-9A-Z]+[-|\\.]?)+[a-z0-9A-Z]@([a-z0-9A-Z]+(-[a-z0-9A-Z]+)?\\.)"
            + "+[a-zA-Z]{2,}$";
    /**
     * 密码匹配
     */
    public static final String regex_pwd = "^[a-zA-Z0-9]\\w{5,16}$";// 密码长度在6~16之间，只能包含字符、数字和下划线
    /**
     * 中文正则表达式
     */
    public static final String regex_ch = "[\\u4E00-\\u9FFF]";
}
